fi.foyt.svg.svgdom.FNISVGPathElementSegment = Class.create({
  initialize: function(command, absolute, parameters){
    this.command = command;
    this.absolute = absolute;
    this.parameters = parameters == null ? new Array() : parameters;
  },
  addParameter: function (x, y) {
    this.parameters.push({x: x, y: y});
  },
  getParameters: function(){
    return this.parameters;
  },
  isAbsolute: function(){
    return this.absolute;
  },
  toString: function(){     
  var result = (this.isAbsolute() ? this.command : this.command.toLowerCase()) + ((this.parameters.length > 0) ? this.parameters[0].x + ' ' + this.parameters[0].y : '');    
  for (var i = 1; i < this.parameters.length; i++) 
      result += ' ' + this.parameters[i].x + ' ' + this.parameters[i].y;
    return result;
  }
});